<%@ page language="java" contentType="text/html; charset=windows-1255"
	pageEncoding="windows-1255"%>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01 Transitional//EN" "http://www.w3.org/TR/html4/loose.dtd">
<%@page import="com.aluna.openxml.util.Accessor"%>
<%@page import="java.util.List"%>
<%@page import="java.text.DateFormat"%>
<%@page import="com.aluna.openxml.data.StockHistoryValue"%>
<html>
<head>
<meta http-equiv="Content-Type"
	content="text/html; charset=windows-1255">
<title>Your Portfolio</title>
<style type="text/css">
.tableHeader {
	text-align: center;
}
.valueColumn {
	text-align: right;
}
</style>
</head>
<link rel="stylesheet" type="text/css" href="css/styles.css?v=57"
	media="all" />
<body>

<div id="ajax-poster-photo">
<div id="ajax-poster-photo-logo-nav-container"
	style="left: -52px; top: 0px; width: 803px"><img
	src="images/microsoft_office_logo.jpg" alt="Microsoft"
	style="width:75px;height:75px;" />
<h1 style="color: white">Your Portfolio</h1>
</div>
</div>

<table cellpadding="0" cellspacing="0" border="0" id="layouttable">
<tr>
	<td valign="top">
		<table>
			<tr>
			<td width="100%">
			<div id="content">
			<div id="content-top">
			<div>
			<div><!-- top corners and border --></div>
			</div>
			</div>
			<div id="content-middle">
			<div id="content-middle2">
			<table>
				<tr>
					<td><a href="list.jsp">Back</a></td>
				</tr>
				<tr>
					<td><a href="CreateGraph.xlsx?ticket=<%= request.getParameter("ticket") %>">Generate Graph</a></td>
				</tr>
			</table>
			<br />
			<img alt="" src="images/spacer.gif" width="100px" height="1px" />
			<div id="topright-decoration"></div>
			</div>
			</div>
			</div>
			</td>
			</tr>
		</table>
	</td>
		<td >
		<div id="content">
		<div id="content-top">
		<div>
		<div><!-- top corners and border --></div>
		</div>
		</div>
		<div id="content-middle">
		<div id="content-middle2">
		<div id="topright-decoration"></div>

		<table>
			<tr>
			<td>Values for stock <strong><%=request.getParameter("ticket")%><strong></td>
			</tr>
		</table>
		<br />

		<table>
			<!-- MSTableType="layout" -->
			<thead>
				<tr style="height: 29px; border-style: solid; border-color: #648ABD; background-color: #7395C1">
					<td style="width: 81px; height: 29px" class="tableHeader"><strong>Date</strong></td>
					<td style="width: 132px; height: 29px" class="tableHeader"><strong>Value
					(USD)</strong></td>
				</tr>
			</thead>

			<%
				Accessor access = (Accessor) session.getAttribute("accessor");
				List<StockHistoryValue> list = access.loadStockHistoryList(request
						.getParameter("ticket"));
				DateFormat format = DateFormat.getDateInstance(DateFormat.SHORT);

				for (StockHistoryValue stock : list) {
			%>
			<tr>
				<td><%=format.format(stock.getDate())%></td>
				<td class="valueColumn"><%=stock.getValue()%>$</td>
			</tr>

			<%
			}
			%>

		</table>
		<br />
		</div>
		</div>
		</div>
		</td>
	</tr>
</table>


</body>
</html>
